import json

class UserInfo:
    
    email = ""
    name = ""
    password = ""
    qq = ""
    def __init__(self,emiail,name,password,qq):
        self.email = emiail
        self.name = name
        self.password = password
        self.qq = qq

    def __str__(self):
        return "邮箱:{},名字:{},密码:{},qq:{}".format(self.email,self.name,self.password,self.qq)

txt = json.load(open("C:\\Users\\Administrator\\Desktop\\txt.json",'r',encoding="utf-8"))
userlist = []

for i in txt:
    userlist.append(UserInfo(i['email'],i['name'],i['password'],i['qq']))

for i in userlist:
    print(i)


